package com.hz.web.service.impl;

import com.hz.web.dao.CompanyBaseInfoMapper;
import com.hz.web.entity.CompanyBaseInfo;
import com.hz.web.entity.Employee;
import com.hz.web.service.ICompanyBaseService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

@Service
public class CompanyBaseImpl implements ICompanyBaseService {

    @Resource
    private CompanyBaseInfoMapper companyBaseInfoMapper;


    @Override
    public int insertSelective(CompanyBaseInfo entity) {
        return companyBaseInfoMapper.insertSelective(entity);
    }

    @Override
    public int insert(CompanyBaseInfo entity) {
        return companyBaseInfoMapper.insert(entity);
    }

    @Override
    public int updateById(CompanyBaseInfo entity) {
        return companyBaseInfoMapper.updateByPrimaryKeySelective(entity);
    }

    /**
     * 查询用户集合
     *
     * @param map
     * @return
     */

    @Override
    public List<CompanyBaseInfo> queryList(Map<String, Object> map) {
        return companyBaseInfoMapper.queryList(map);
    }

    /**
     * 查询用户表总数量
     *
     * @param map
     * @return
     */
    @Override
    public int queryCount(Map<String, Object> map) {

        return companyBaseInfoMapper.queryCount(map);
    }

    @Override
    public CompanyBaseInfo selectByUserId(Integer userId) {
        return companyBaseInfoMapper.selectByUserId(userId);
    }


}
